<? include 'server_config.php'; 

if($_SESSION['user_idx'] == "")
{
	?>
	<script>
		location.href='login.php';
	</script>
	<?
	return;
}

?>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8">

<?

if ($_GET['friend_idx'] == "")
{
	?>
	<script>
		location.href="friends.php?cache=<? echo rand(1,1000);?>";
	</script>
	<?
	return;
}

//기존 비밀번호가 일치하지 않을 경우 - exit

$sql="
	DELETE FROM ndd_friends WHERE friend_idx='".$_GET['friend_idx']."' LIMIT 1;
";
$result = mysql_query($sql,$connect);


?>

<script> 
location.href="friends.php?cache=<? echo rand(1,1000);?>";
</script>











